/*
 * @Author: your name
 * @Date: 2021-05-29 17:03:51
 * @LastEditTime: 2021-06-05 14:46:57
 * @LastEditors: Please set LastEditors
 * @Description: In User Settings Edit
 * @FilePath: \oop1\HW3\main.cpp
 */
#include <iostream>
// #include "task1/stuff.h"
// #include "task2/teacherAndStudent.h"
// #include "task3/triangle.h"
#include "task2InWeChatGroup/myArray.hpp"
#include "task1InWeChatGroup/bioTree.hpp"
using namespace std;
int main()
{
<<<<<<< HEAD
<<<<<<< HEAD
=======
    
>>>>>>> bcdac5bade03a18c76d0ce4ec61a22ec56cdbfd5
=======
    
>>>>>>> 3a15fcc8e787269c0dba769af20aaf4d463ba208
    // task1_TB();
    // detect(1,2,3);
    // test2();
    int a[10]={1,2,3,4,5,6,7,8,9,12};
    int index =bisearch<int>(a,5,10);
    cout<<"输入序列为[1,2,3,4,5,6,7,8,9,12]"<<endl;
    cout<<"查找值为5的序号"<<endl;
    cout <<"所在序号为"<<index+1<<endl;

    char * str="TongjiUniversity David";

	int length=22; // 一共22个字符
	
	for (int i =0;i<length;++i)
	{
        char wkstr[22];
        for (int j =0;j<length;++j)
        {
            wkstr[j]=*(str+(j+i)%length);
        }
        cout <<wkstr<<endl;
	}
    // myArray<int> arr(10);
    // arr.push_back(1);
    // arr.push_back(9);
    // arr.push_back(7);
    // arr.push_back(3);
    // arr.push_back(6);
    // arr.push_back(2);
    // arr.push_back(5);
    // cout << "输入序列：[1,9,7,3,6,2,5],float double 等雷同" << endl;
    // cout << "快速排序" << endl;
    // arr.sort();
    // arr.print();
    // cout << "输入序列：[a,d,c,h,f,s,q,w]" << endl;
    // cout << "快速排序" << endl;
    // myArray<char> arr2(10);
    // arr2.push_back('a');
    // arr2.push_back('d');
    // arr2.push_back('c');
    // arr2.push_back('h');
    // arr2.push_back('f');
    // arr2.push_back('s');
    // arr2.push_back('q');
    // arr2.push_back('w');
    // arr2.sort();
    // arr2.print();
    // cout<<"事实上只要对模板类定义> < == 等操作，即可实现任意类的排序。同时，函数指针、比较结构体等也可以实现同样的效果"<<endl;
    return 0;
}
